package rsb212.num23.ysh.d1113;


public abstract class Animal {
    protected String name;

    public Animal() {
    }

    public Animal(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }



    protected abstract void shout();
    protected void eat(Food f){
        System.out.print(this.name+"正在吃着"+f.getName());
    }

}

